package com.hm.shopping.domain;

import java.util.List;

import org.springframework.data.mongodb.core.mapping.Document;
import org.springframework.data.mongodb.core.mapping.Field;

import com.hm.shopping.auto.su.BaseDomain;
import com.hm.shopping.auto.su.R;

import lombok.Getter;
import lombok.Setter;

/**
 * @author shishun.wang
 * @date 2018年2月9日 下午3:40:27
 * @version 1.0
 * @describe 我的购物车
 */
@Setter
@Getter
@Document(collection = R.Database.prefix + "SHOPCART")
public class ShopcartDomain extends BaseDomain {

	private static final long serialVersionUID = 8741776505793067329L;

	/**
	 * 买家
	 */
	@Field(value = "buyer_id")
	private String buyerId;

	/**
	 * 商品id
	 */
	@Field(value = "goods_id")
	private String goodsId;

	/**
	 * 加入购物车商品属性
	 */
	@Field(value = "goods_attributes")
	private List<String> goodsAttributes;
	
	/**
	 * 商品默认勾选
	 */
	private boolean selected = true;

	/**
	 * 商品数量
	 */
	private int quantity;

}
